﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Test_Libscvs.Instrument;

namespace Test_Libscvs
{
    public class scpi
    {
        public static Load_Set _Load_OI = new Load_Set();
        public static double my_add(double a, double b)
        {
            double c = a + b;
            return c;
        }
        public static string load_init(string info, bool is_sim, bool is_rst)
        {
            info = _Load_OI.Load_initial(info, is_sim, is_rst);//初始化电子负载
            if (!info.Contains("Fail"))
            {
                _Load_OI.Setmode("CC");//设置电子负载模式 CC
                _Load_OI.INPOFF();//开关断开
            }
            return info;
        }
        public static bool load_cls()
        {
            _Load_OI.close_session();//断开电子负载连接
            return true;
        }
    }
}
